home *** CD-ROM | disk | FTP | other *** search
/ NeXT Education Software Sampler 1992 Fall / NeXT Education Software Sampler 1992 Fall.iso / Mathematics / Notebooks / PartialDifferentials / pdeintro.ma < prev    next >
Encoding:
Mathematica notebook  |  1992-08-04  |  22.4 KB  |  420 lines

  1. (*^
  2.  
  3. ::[automaticGrouping; magnification = 125; currentKernel; 
  4.     fontset = title, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M7, bold, L1, e8,  24, "Times"; ;
  5.     fontset = subtitle, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M7, bold, L1, e6,  18, "Times"; ;
  6.     fontset = subsubtitle, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M7, italic, L1, e6,  14, "Times"; ;
  7.     fontset = section, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, grayBox, M22, bold, L1, a20,  18, "Times"; ;
  8.     fontset = subsection, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, blackBox, M19, bold, L1, a15,  14, "Times"; ;
  9.     fontset = subsubsection, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, whiteBox, M18, bold, L1, a12,  12, "Times"; ;
  10.     fontset = text, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  11.     fontset = smalltext, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  10, "Times"; ;
  12.     fontset = input, noPageBreakBelow, nowordwrap, preserveAspect, groupLikeInput, M42, N23, bold, L1,  12, "Courier"; ;
  13.     fontset = output, output, inactive, noPageBreakBelow, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, L-5,  12, "Courier"; ;
  14.     fontset = message, inactive, noPageBreakBelow, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, L1,  12, "Courier"; ;
  15.     fontset = print, inactive, noPageBreakBelow, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, L1,  12, "Courier"; ;
  16.     fontset = info, inactive, noPageBreakBelow, nowordwrap, preserveAspect, groupLikeOutput, M42, N23, L1,  12, "Courier"; ;
  17.     fontset = postscript, PostScript, formatAsPostScript, output, inactive, noPageBreakBelow, nowordwrap, preserveAspect, groupLikeGraphics, M7, l34, w282, h287, L1,  12, "Courier"; ;
  18.     fontset = name, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, italic, L1,  10, "Times"; ;
  19.     fontset = header, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  20.     fontset = Left Header, nohscroll, cellOutline,  12;
  21.     fontset = footer, inactive, nohscroll, noKeepOnOnePage, preserveAspect, center, M7, L1,  12;
  22.     fontset = Left Footer, cellOutline, blackBox,  12;
  23.     fontset = help, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  10, "Times"; ;
  24.     fontset = clipboard, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  25.     fontset = completions, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12, "Courier"; ;
  26.     fontset = special1, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  27.     fontset = special2, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  28.     fontset = special3, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  29.     fontset = special4, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  30.     fontset = special5, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M7, L1,  12;
  31.     next21StandardFontEncoding; ]
  32. :[font = title; inactive; preserveAspect; startGroup; ]
  33. Partial Differential
  34. Equations
  35. through Mathematica 
  36. ;[s]
  37. 3:0,0;39,1;50,2;52,-1;
  38. 3:1,21,16,Times,1,24,0,0,0;1,22,17,Times,3,24,0,0,0;1,21,16,Times,1,24,0,0,0;
  39. :[font = section; inactive; Cclosed; preserveAspect; startGroup; ]
  40. Introduction
  41. :[font = text; inactive; preserveAspect; ]
  42. We illustrate the use of Mathematica in the following
  43. areas.  Section numbers refer to sections in Mark Pinsky's
  44. ;[s]
  45. 3:0,0;25,1;36,2;112,-1;
  46. 3:1,11,8,Times,0,12,0,0,0;1,10,8,Times,2,12,0,0,0;1,11,8,Times,0,12,0,0,0;
  47. :[font = text; inactive; preserveAspect; ]
  48. Partial Differential Equations
  49. and Boundary Value Problems with Applications,
  50. McGraw-Hill, New York, 1991.
  51. ;[s]
  52. 2:0,0;76,1;106,-1;
  53. 2:1,10,8,Times,1,12,0,0,0;1,11,8,Times,0,12,0,0,0;
  54. :[font = text; inactive; preserveAspect; ]
  55. Computing Fourier coefficients (Section 1.1)
  56. Graphing Fourier series (Sections 1.1, 1.3 and 1.4)
  57. Computing and graphing Legendre polynomials (Section 4.2)
  58. Graphing 3-dimensional plots of heat flow (Section 2.1)
  59. Computing and graphing Bessel Functions (Section 3.2)
  60. Graphing and animating 3-dimensional plots of a
  61. vibrating drum (Sections 2.5 and 3.3)
  62. Bifurcation of the wave equation (Section 2.4)
  63. :[font = text; inactive; preserveAspect; ]
  64. The essential references for Mathematica are the well-written books
  65. ;[s]
  66. 3:0,0;29,1;40,2;68,-1;
  67. 3:1,11,8,Times,0,12,0,0,0;1,10,8,Times,2,12,0,0,0;1,11,8,Times,0,12,0,0,0;
  68. :[font = text; inactive; preserveAspect; ]
  69. Mathematica  by Steven Wolfram,
  70. Programming in Mathematica  by Roman Maeder,
  71. Mathematica: A Practical Approach  by N. Blachman.
  72. ;[s]
  73. 13:0,0;11,1;12,2;32,3;43,4;44,5;47,6;58,7;59,8;77,9;88,10;90,11;112,12;127,-1;
  74. 13:1,10,8,Times,3,12,0,0,0;1,10,8,Times,1,12,0,0,0;1,11,8,Times,0,12,0,0,0;1,10,8,Times,1,12,0,0,0;1,11,8,Times,0,12,0,0,0;1,10,8,Times,1,12,0,0,0;1,10,8,Times,3,12,0,0,0;1,10,8,Times,1,12,0,0,0;1,11,8,Times,0,12,0,0,0;1,10,8,Times,3,12,0,0,0;1,11,8,Times,0,12,0,0,0;1,10,8,Times,3,12,0,0,0;1,11,8,Times,0,12,0,0,0;
  75. :[font = text; inactive; pageBreakBelow; preserveAspect; endGroup; ]
  76. The books by Wolfram and Maeder are published by Addison-Wesley,
  77. and the book by Blachman is published by Prentice-Hall.
  78. ;[s]
  79. 2:0,0;119,1;120,-1;
  80. 2:1,11,8,Times,0,12,0,0,0;1,10,8,Courier,1,12,0,0,0;
  81. :[font = section; inactive; Cclosed; preserveAspect; startGroup; ]
  82. Getting Started
  83. :[font = text; inactive; preserveAspect; ]
  84. Here are simple instructions for getting started with Mathematica on a
  85. NeXT workstation; the instructions for a Mac or a PC with windows are quite
  86. similar. First you need to logon.  To bring up Mathematica you should click
  87. on the Mathematica icon (it is a small polyhedron).  This brings up a window
  88. called "Untitled"; it is actually a notebook. To enter a formula just start typing.
  89. For example, the polynomial
  90. ;[s]
  91. 7:0,0;54,1;65,2;194,3;205,4;230,5;241,6;411,-1;
  92. 7:1,11,8,Times,0,12,0,0,0;1,10,8,Times,2,12,0,0,0;1,11,8,Times,0,12,0,0,0;1,10,8,Times,2,12,0,0,0;1,11,8,Times,0,12,0,0,0;1,10,8,Times,2,12,0,0,0;1,11,8,Times,0,12,0,0,0;
  93. :[font = postscript; PostScript; formatAsPostScript; output; inactive; preserveAspect; pictureLeft = 0; pictureWidth = 37; pictureHeight = 14; ]
  94. %!
  95. %%Creator: Mathematica
  96. %%AspectRatio: 0.378378
  97. 200 dict begin
  98. MathPictureStart
  99. /Courier findfont 10  scalefont  setfont
  100. % Scaling calculations
  101. 0 1 0 1 [
  102. [ 0 0 0 0 ]
  103. [ 37 14 0 0 ]
  104. ] MathScale
  105. % Start of Graphics
  106. %!PS-Adobe-2.0 EPSF-2.0
  107. %%Title: 
  108. %%Creator: EquationBuilder
  109. %%CreationDate: Mon Aug  3 17:47:55 1992
  110. %%For: gray
  111. %%DocumentFonts: (atend)
  112. %%Pages: 0 1
  113. %%BoundingBox: 0 0 37 14
  114. %%Translation: 1 0.156 35.121334 0
  115. %%EndComments
  116.  
  117. %%BeginDocument: /usr/lib/NextStep/printPackage.ps
  118. %!PS-Adobe-2.0
  119. %%Title: Printing Package
  120. %%EndComments
  121. %Version: 2.0
  122. %Copyright: 1988, NeXT, Inc.
  123.  
  124. /__NXdef{1 index where{pop pop pop}{def}ifelse}bind def
  125. /__NXbdef{1 index where{pop pop pop}{bind def}ifelse}bind def
  126. /UserObjects 10 array __NXdef
  127. /defineuserobject{
  128.     exch dup 1 add dup UserObjects length gt{
  129.         array dup 0 UserObjects putinterval
  130.         /UserObjects exch def
  131.     }{pop}ifelse UserObjects exch 3 -1 roll put
  132. }__NXbdef
  133. /undefineuserobject{UserObjects exch null put}__NXbdef
  134. /execuserobject{UserObjects exch get exec}__NXbdef
  135. /__NXRectPath{4 2 roll moveto 1 index 0 rlineto
  136. 0 exch rlineto neg 0 rlineto closepath}__NXbdef
  137. /__NXProcessRectArgs{
  138.     1 index type /arraytype eq{
  139.         exch 0 4 2 index length 1 sub{
  140.             dup 3 add 1 exch{1 index exch get exch}for
  141.             5 1 roll 5 index exec
  142.         }for pop pop
  143.     }{exec}ifelse
  144. }__NXbdef
  145. /rectfill{gsave newpath {__NXRectPath fill} __NXProcessRectArgs grestore}__NXbdef
  146. /rectclip{newpath {__NXRectPath} __NXProcessRectArgs clip newpath}__NXbdef
  147. /rectstroke{
  148.     gsave newpath dup type /arraytype eq{dup length 6 eq}{false}ifelse{
  149.         {gsave __NXRectPath null concat stroke grestore}
  150.         dup length array cvx copy dup 2 4 -1 roll put __NXProcessRectArgs
  151.     }{{__NXRectPath stroke} __NXProcessRectArgs}ifelse grestore
  152. }__NXbdef
  153. /xyshow{
  154.     0 1 3 index length 1 sub{
  155.         currentpoint 4 index 3 index 1 getinterval show
  156.         3 index 3 index 2 mul 1 add get add exch
  157.         3 index    3 index 2 mul get add exch moveto pop
  158.     }for pop pop
  159. }__NXbdef
  160. /xshow{
  161.     0 1 3 index length 1 sub{
  162.         currentpoint 4 index 3 index 1 getinterval show
  163.         exch 3 index 3 index get add exch moveto pop
  164.     }for pop pop
  165. }__NXbdef
  166. /yshow{
  167.     0 1 3 index length 1 sub{
  168.         currentpoint 4 index 3 index 1 getinterval show
  169.         3 index 3 index get add moveto pop
  170.     }for pop pop
  171. }__NXbdef
  172. /arct{arcto pop pop pop pop}__NXbdef
  173. /setbbox{pop pop pop pop}__NXbdef
  174. /ucache{}__NXbdef
  175. /ucachestatus{mark 0 0 0 0 0}__NXbdef
  176. /setucacheparams{cleartomark}__NXbdef
  177. /uappend{systemdict begin cvx exec end}__NXbdef
  178. /ueofill{gsave newpath uappend eofill grestore}__NXbdef
  179. /ufill{gsave newpath uappend fill grestore}__NXbdef
  180. /ustroke{
  181.     gsave newpath dup length 6 eq
  182.     {exch uappend concat}{uappend}ifelse
  183.     stroke grestore
  184. }__NXbdef
  185. /__NXustrokepathMatrix dup where {pop pop}{matrix def}ifelse
  186. /ustrokepath{
  187.     newpath dup length 6 eq{
  188.         exch uappend __NXustrokepathMatrix currentmatrix exch concat
  189.         strokepath setmatrix
  190.     }{uappend strokepath}ifelse
  191. } __NXbdef
  192. /upath{
  193.     [exch {/ucache cvx}if pathbbox /setbbox cvx
  194.      {/moveto cvx}{/lineto cvx}{/curveto cvx}{/closepath cvx}pathforall]cvx
  195. } __NXbdef
  196. /setstrokeadjust{pop}__NXbdef
  197. /currentstrokeadjust{false}__NXbdef
  198. /selectfont{exch findfont exch
  199. dup type /arraytype eq {makefont}{scalefont}ifelse setfont}__NXbdef
  200. /_NXCombineArrays{
  201.     counttomark dup 2 add index dup length 3 -1 roll {
  202.         2 index length sub dup 4 1 roll 1 index exch 4 -1 roll putinterval exch
  203.     }repeat pop pop pop
  204. }__NXbdef
  205. /setcmykcolor{
  206.     1.0 exch sub dup dup 6 -1 roll
  207.     sub dup 0 lt{pop 0}if 5 1 roll
  208.     4 -1 roll sub dup 0 lt{pop 0}if 3 1 roll
  209.     exch sub dup 0 lt{pop 0}if setrgbcolor
  210. }__NXbdef
  211. /currentcmykcolor{currentrgbcolor 3{1.0 exch sub 3 1 roll}repeat 0}__NXbdef
  212. /flushgraphics{}def
  213. /setwindowtype{pop pop}def
  214. /currentwindowtype{pop 0}def
  215. /setalpha{pop}def
  216. /currentalpha{1.0}def
  217. /hidecursor{}def
  218. /obscurecursor{}def
  219. /revealcursor{}def
  220. /setcursor{4 {pop}repeat}bind def
  221. /showcursor{}def
  222. /NextStepEncoding where not{
  223. /NextStepEncoding StandardEncoding 256 array copy def
  224. 0 [129/Agrave/Aacute/Acircumflex/Atilde/Adieresis/Aring/Ccedilla/Egrave
  225. /Eacute/Ecircumflex/Edieresis/Igrave/Iacute/Icircumflex/Idieresis
  226. /Eth/Ntilde/Ograve/Oacute/Ocircumflex/Otilde/Odieresis/Ugrave/Uacute
  227. /Ucircumflex/Udieresis/Yacute/Thorn/mu/multiply/divide/copyright
  228. 176/registered 181/brokenbar 190/logicalnot 192/onesuperior 201/twosuperior
  229. 204/threesuperior 209/plusminus/onequarter/onehalf/threequarters/agrave
  230. /aacute/acircumflex/atilde/adieresis/aring/ccedilla/egrave/eacute
  231. /ecircumflex/edieresis/igrave 226/iacute 228/icircumflex/idieresis/eth
  232. /ntilde 236/ograve/oacute/ocircumflex/otilde/odieresis 242/ugrave/uacute
  233. /ucircumflex 246/udieresis/yacute 252/thorn/ydieresis]
  234. {dup type /nametype eq
  235.  {NextStepEncoding 2 index 2 index put pop 1 add}{exch pop}ifelse
  236. }forall pop
  237. /NextStepEncoding NextStepEncoding readonly def   
  238. /_NXfstr 128 string dup 0 (_NX) putinterval def   
  239. /findfont{
  240.  % Because we can never let NextStepEncoding get into
  241.  % SharedFontDirectory, we cannot reencode a font to NextStepEncoding
  242.  % if we are in shared mode.  So if currentshared is true,
  243.  % we call the normal findfont and return that
  244.  /currentshared where {pop currentshared} {false} ifelse
  245.  {//findfont exec}
  246.  {dup _NXfstr 3 125 getinterval cvs length 3 add _NXfstr 0 3 -1 roll
  247.   getinterval cvn exch FontDirectory 2 index known 
  248.   {pop FontDirectory exch get}
  249.   {//findfont exec dup /Encoding get StandardEncoding eq
  250.    {    dup length dict exch
  251.     {1 index /FID ne {2 index 3 1 roll put}{pop pop}ifelse}forall
  252.      dup /Encoding NextStepEncoding put definefont
  253.     }{exch pop} ifelse
  254.    }ifelse
  255.  }ifelse
  256. }bind def
  257. }{pop}ifelse
  258. /_NXProcArray 5 array __NXdef
  259. /_NXChannels 0 __NXdef
  260. /_NXTotalBytes 0 __NXdef
  261. /_NXDoImageOp{
  262.     1 index{dup}{1}ifelse /_NXChannels exch store
  263.     _NXChannels 2 add 2 roll _NXProcArray 0 _NXChannels getinterval astore pop
  264.     5 index 4 index mul 2 index{1 sub 8 idiv 1 add mul}{mul 1 sub 8 idiv 1 add}ifelse
  265.     4 index mul /_NXTotalBytes exch store pop exch pop
  266.     gsave matrix invertmatrix concat 0.5 setgray 0 0 4 2 roll rectfill grestore
  267.     {    0 1 _NXChannels 1 sub{
  268.             _NXProcArray exch get exec
  269.             length _NXTotalBytes exch sub /_NXTotalBytes exch store}for
  270.         _NXTotalBytes 0 le{exit}if
  271.     }loop /_NXProcArray 5 array def
  272. }__NXbdef
  273. /colorimage{_NXDoImageOp}__NXbdef
  274. /alphaimage{1 add _NXDoImageOp}def
  275. %%EndDocument
  276.  
  277. % EquationBuilder(TM) Expression
  278. % +.\Jr(=:/*V[StRFQAYmdjEEA;1nuN+[co.OZ7L#cq3iK%3:</XJ@:d#6;^G;Td47dud<A3@
  279. % 5%MGToUOR5&d`'TuEDU)B-tbR".RTS*D@!!!E766YS9+CLB'j@P.-O?%B4'FH)c:eX1]TM0'
  280. % o;,/#l!%\^3YU,#41L183Q(&Hf"9NTgc2h<D&k0$!hQXOnBCNsA60Psq6cY@ca,g65@$1_&!
  281. % 4;jU%&gaK#*:He)*F$K-B4KKEq1J^9P5%"9R]'S)A)2;Jgl!!L_7:gEQ')7;"ni:fi)]`HjL
  282. % )jRM8_O9-sb>TGRZ^.I)-d&^jYV\,af04qeP4q:'DuV4'URE;e;ZLbZ9#Ir(^<D"R"d[soKm
  283. % L*8qK!T9JsYCQ2)Fse$P"rm^S2bJ;f+U;Cr"mAI4HP_8X85b*ln6^\JZ:BfuTh&X!//$Y`KP
  284. % @BaVANeR4pG5Ep^(%GHPc8)Jpabm2kbcfm72s^+6LUM0*_,]gCSMK0uk5R%-Q>S443h5M!al
  285. % ##q-(\[Du*l0T^ecmk$dn)JuG&JeX,siPp3US=/LZ/I3L:)+i0e"rh98nX]f&WbEh"A:P:`!
  286. % !3LZBFmFB\0qoT&.m5+6#Zl*-iOqax
  287. % EndExpression N 484 1e4 E c5 S c295 R 4a4004b3
  288. gsave
  289.  /__NXbasematrix matrix currentmatrix def
  290. grestore
  291. %%EndProlog
  292. %%BeginSetup
  293. /EqBFont 18 dict dup begin /FontType 3 def /PaintType 0 def /FontMatrix [0.001 0 0 0.001 0 0] def /FontBBox [15 -2950 1360 1045] def /Encoding [/.notdef /rad1 /rad2 /rad3 /rad4 /rad5 /radext /int /pathint /sum /prod /cdot /vdot /ddot /hbar /bigcap /bigcup /parallel] def /Metrics 18 dict dup begin /.notdef 0 def /rad1 1000 def /rad2 1000 def /rad3 1000 def /rad4 1000 def /rad5 1048 def /radext 1048 def /int 500 def /pathint 500 def /sum 700 def /prod 700 def /cdot 1000 def /vdot 550 def /ddot 1000 def /hbar 500 def /bigcap 700 def /bigcup 700 def /parallel 500 def end def /BBox 18 dict dup begin /.notdef [0 0 0 0] def /rad1 [110 -1150 1020 0] def /rad2 [110 -1750 1020 0] def /rad3 [110 -2350 1020 0] def /rad4 [110 -2950 1020 0] def /rad5 [128 -2890 740 0] def /radext [700 -600 740 0] def /int [20 0 425 1045] def /pathint [20 0 425 1045] def /sum [15 5 640 715] def /prod [15 0 670 715] def /cdot [110 215 890 325] def /vdot [165 -5 280 770] def /ddot [110 -5 890 770] def /hbar [20 -10 480 685] def /bigcap [0 0 680 720] def /bigcup [0 0 680 720] def /parallel [65 -175 400 675] def end def /CharacterDefs 18 dict dup begin /.notdef {
  294.     
  295. } def /rad1 {
  296.     980 0 moveto 464 -1048 lineto 248 -560 lineto 110 -656 lineto 125 -675 lineto 200 -624 lineto 420 -1150 lineto 460 -1150 lineto 1020 0 lineto 980 0 lineto closepath
  297. } def /rad2 {
  298.     980 0 moveto 460 -1600 lineto 245 -864 lineto 110 -1000 lineto 128 -1023 lineto 200 -950 lineto 424 -1750 lineto 456 -1750 lineto 1020 0 lineto 980 0 lineto closepath
  299. } def /rad3 {
  300.     980 0 moveto 464 -2144 lineto 248 -1160 lineto 110 -1368 lineto 130 -1390 lineto 192 -1288 lineto 424 -2350 lineto 464 -2350 lineto 1020 0 lineto 980 0 lineto closepath
  301. } def /rad4 {
  302.     980 0 moveto 880 -488 lineto 672 -1600 lineto 464 -2696 lineto 248 -1464 lineto 110 -1728 lineto 130 -1750 lineto 192 -1616 lineto 424 -2950 lineto 464 -2950 lineto 768 -1312 lineto 1020 0 lineto 980 0 lineto closepath
  303. } def /rad5 {
  304.     700 0 moveto 700 -2628 lineto 248 -1284 lineto 128 -1564 lineto 150 -1580 lineto 215 -1425 lineto 688 -2890 lineto 740 -2890 lineto 740 0 lineto 700 0 lineto closepath
  305. } def /radext {
  306.     700 0 moveto 700 -600 lineto 740 -600 lineto 740 0 lineto 700 0 lineto closepath
  307. } def /int {
  308.     245 390 moveto 225 235 195 145 180 100 curveto 165 60 150 50 140 40 curveto 135 30 85 0 50 20 curveto 35 25 25 45 25 55 curveto 20 80 30 100 55 110 curveto 80 125 93 110 110 90 curveto 135 60 155 135 160 195 curveto 165 270 170 340 190 510 curveto 205 650 lineto 220 810 230 890 265 960 curveto 275 980 295 1015 320 1030 curveto 350 1045 380 1030 395 1020 curveto 410 1010 425 980 400 955 curveto 385 940 347 925 330 950 curveto 310 970 290 955 290 940 curveto 280 900 285 745 270 610 curveto 245 390 lineto closepath
  309. } def /pathint {
  310.     245 390 moveto 225 235 195 145 180 100 curveto 165 60 150 50 140 40 curveto 135 30 85 0 50 20 curveto 35 25 25 45 25 55 curveto 20 80 30 100 55 110 curveto 80 125 93 110 110 90 curveto 135 60 155 135 160 195 curveto 165 270 170 340 190 510 curveto 205 650 lineto 220 810 230 890 265 960 curveto 275 980 295 1015 320 1030 curveto 350 1045 380 1030 395 1020 curveto 410 1010 425 980 400 955 curveto 385 940 347 925 330 950 curveto 310 970 290 955 290 940 curveto 280 900 285 745 270 610 curveto 245 390 lineto fill 20 setlinewidth 220 400 moveto 290 400 340 455 340 500 curveto 340 585 290 640 220 640 curveto 155 640 100 585 100 500 curveto 100 455 155 400 220 400 curveto stroke
  311. } def /sum {
  312.     330 335 moveto 20 715 lineto 575 715 lineto 600 545 lineto 575 535 lineto 550 625 525 685 395 685 curveto 160 685 lineto 411 370 lineto 160 90 lineto 470 90 lineto 565 90 590 140 610 210 curveto 640 200 lineto 585 5 lineto 15 5 lineto 330 335 lineto closepath
  313. } def /prod {
  314.     590 90 moveto 590 30 620 20 670 20 curveto 670 0 lineto 410 0 lineto 410 20 lineto 460 20 495 30 495 90 curveto 495 670 lineto 190 670 lineto 190 90 lineto 190 30 225 20 275 20 curveto 275 0 lineto 15 0 lineto 15 20 lineto 65 20 100 30 100 90 curveto 100 615 lineto 100 690 40 700 20 700 curveto 20 715 lineto 670 715 lineto 670 700 lineto 645 700 590 690 590 615 curveto 590 90 lineto closepath
  315. } def /cdot {
  316.     110 270 moveto 110 300 135 325 165 325 curveto 195 325 220 300 220 270 curveto 220 235 185 215 165 215 curveto 145 215 110 235 110 270 curveto fill 445 270 moveto 445 300 470 325 500 325 curveto 530 325 555 300 555 270 curveto 555 235 520 215 500 215 curveto 480 215 445 235 445 270 curveto fill 775 270 moveto 775 300 800 325 830 325 curveto 860 325 890 300 890 270 curveto 890 235 850 215 830 215 curveto 810 215 775 235 775 270 curveto fill
  317. } def /vdot {
  318.     220 770 moveto 250 770 280 750 280 720 curveto 280 680 250 660 220 660 curveto 185 660 165 695 165 720 curveto 165 740 185 770 220 770 curveto fill 220 440 moveto 250 440 280 415 280 385 curveto 280 355 250 330 220 330 curveto 185 330 165 365 165 385 curveto 165 405 185 440 220 440 curveto fill 220 105 moveto 250 105 280 80 280 50 curveto 280 20 250 -5 220 -5 curveto 185 -5 165 30 165 50 curveto 165 70 185 105 220 105 curveto fill
  319. } def /ddot {
  320.     165 720 moveto 205 720 220 700 220 665 curveto 220 630 195 610 165 610 curveto 130 620 110 645 110 665 curveto 110 690 130 720 165 720 curveto fill 500 440 moveto 530 440 555 415 555 385 curveto 555 355 530 330 500 330 curveto 465 330 445 365 445 385 curveto 445 405 465 440 500 440 curveto fill 830 155 moveto 860 155 890 130 890 100 curveto 890 70 860 45 830 45 curveto 795 45 775 80 775 100 curveto 775 120 795 155 830 155 curveto fill
  321. } def /hbar {
  322.     480 105 moveto 440 55 400 -10 335 -10 curveto 300 -10 290 10 290 35 curveto 290 65 370 350 370 365 curveto 370 380 355 390 340 390 curveto 290 390 205 275 185 250 curveto 140 180 125 125 95 0 curveto 20 0 lineto 150 500 lineto 160 545 180 600 180 615 curveto 180 625 170 640 135 640 curveto 110 640 lineto 100 655 lineto 165 660 215 670 270 685 curveto 275 680 lineto 155 240 lineto 155 235 lineto 190 290 290 440 380 440 curveto 400 440 450 435 450 370 curveto 450 335 365 80 365 55 curveto 365 45 375 40 385 40 curveto 405 40 425 70 465 115 curveto 480 105 lineto fill 55 545 moveto 55 520 lineto 310 560 lineto 310 585 lineto 55 545 lineto fill
  323. } def /bigcap {
  324.     615 400 moveto 615 575 500 655 340 655 curveto 180 655 70 575 70 400 curveto 70 0 lineto 5 0 lineto 5 400 lineto 5 610 140 720 340 720 curveto 545 720 680 610 680 400 curveto 680 0 lineto 615 0 lineto 615 400 lineto closepath
  325. } def /bigcup {
  326.     65 320 moveto 65 145 180 65 340 65 curveto 500 65 615 145 615 320 curveto 615 720 lineto 680 720 lineto 680 320 lineto 680 110 540 0 340 0 curveto 140 0 0 110 0 320 curveto 0 720 lineto 65 720 lineto 65 320 lineto closepath
  327. } def /parallel {
  328.     135 675 moveto 135 -175 lineto 65 -175 lineto 65 675 lineto 135 675 lineto fill 335 675 moveto 335 -175 lineto 265 -175 lineto 265 675 lineto 335 675 lineto fill 400 675 moveto
  329. } def end def /BuildChar {
  330.     0 begin /char exch def /fontdict exch def /charname fontdict /Encoding get char get def fontdict begin Metrics charname get 0 BBox charname get aload pop setcachedevice CharacterDefs charname get exec eofill end end
  331. } def /BuildChar load 0 3 dict put end definefont pop
  332. %%EndSetup
  333. gsave
  334. 0 0 36.121334 13.302705 rectclip
  335. 0 0 36.121334 13.302705 rectclip
  336. 0 setgray
  337. 1 setalpha
  338. /Times-BoldItalic findfont 12 scalefont
  339. 44
  340. exch
  341. defineuserobject
  342. 44 execuserobject setfont
  343. 1 1.156 moveto
  344. (x) [0 0 -3.335999 0] xyshow
  345. /Times-Roman findfont 9 scalefont
  346. 46
  347. exch
  348. defineuserobject
  349. 46 execuserobject setfont
  350. 11.5 6.110704 moveto
  351. (51) [-4.5 0 0 0 0 0] xyshow
  352. /Symbol findfont 9 scalefont
  353. 45
  354. exch
  355. defineuserobject
  356. 45 execuserobject setfont
  357. 50.221668 11.078728 moveto
  358. () [-5.427002 0] xyshow
  359. /Symbol findfont 12 scalefont
  360. 47
  361. exch
  362. defineuserobject
  363. 47 execuserobject setfont
  364. 19.866667 1.156 moveto
  365. (-) [0 0 -29.77533 0] xyshow
  366. /Times-Roman findfont 12 scalefont
  367. 70
  368. exch
  369. defineuserobject
  370. 70 execuserobject setfont
  371. 29.121334 1.156 moveto
  372. (1) [0 0 6 0] xyshow
  373. grestore
  374. %%Trailer
  375. %%DocumentFonts: Times-BoldItalic
  376. %%+ Times-Roman
  377. %%+ Symbol
  378.  
  379. %End of Graphics
  380. MathPictureEnd
  381. end
  382.  
  383. :[font = input; preserveAspect; ]
  384.  
  385. :[font = text; inactive; preserveAspect; ]
  386. can be factored by typing
  387. :[font = input; Cclosed; preserveAspect; startGroup; ]
  388. Factor[x^15-1]
  389. :[font = output; output; inactive; preserveAspect; endGroup; ]
  390. (-1 + x)*(1 + x + x^2)*
  391.   (1 + x + x^2 + x^3 + x^4)*
  392.   (1 - x + x^3 - x^4 + x^5 - x^7 + x^8)
  393. ;[o]
  394.                    2
  395. (-1 + x) (1 + x + x ) 
  396.  
  397.             2    3    4
  398.   (1 + x + x  + x  + x ) 
  399.  
  400.             3    4    5    7    8
  401.   (1 - x + x  - x  + x  - x  + x )
  402. :[font = text; inactive; preserveAspect; ]
  403.     Mathematica on a NeXT workstation (as on a Mac or PC with
  404. windows) uses an interface called a "notebook".  Notebooks are divided into
  405. cells.  Each formula is entered into a "cell", recognizable by a bracket on the
  406. right side of the window.  After typing a formula into a cell, you can evaluate
  407. the formula by hitting the key  "Enter".  (Notice that "Enter" is different
  408. from "Return"; the latter is used to go to the next line of a cell. )
  409. ;[s]
  410. 3:0,0;1,1;12,2;441,-1;
  411. 3:1,11,8,Times,0,12,0,0,0;1,10,8,Times,2,12,0,0,0;1,11,8,Times,0,12,0,0,0;
  412. :[font = text; inactive; preserveAspect; endGroup; endGroup; ]
  413. Cells can be used to display either text or graphics and can be printed
  414. individually.  To print a whole notebook, click the mouse on the "print" icon.
  415. To print an individual cell, first you need to use the mouse to move the
  416. cursor to a cell bracket and click on it.  You should see a long dark line
  417. encompassing the cell.  Then move the cursor to the "Print Selection" icon
  418. and click the mouse button. This will bring up a dialog box that allows you
  419. to send the graphics to the printer.
  420. ^*)